package com.jrx.anytxn.customer.dto.bankcardinfo;


import com.jrx.anytxn.common.constant.RegexConstant;
import com.jrx.anytxn.customer.dto.BaseApiReq;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import java.io.Serializable;

/**
 * 银行卡设置默认收还款标志请求参数
 *
 * @author Yangxin
 * @date 2019-08-07 17:32
 **/
@ApiModel(description="银行卡设置默认收还款标志请求参数BankCardSetFlagReq")
public class BankCardSetFlagReq extends BaseApiReq implements Serializable {

    private static final long serialVersionUID = -3874310285666246902L;
    /**
     * 银行卡号
     * 表字段:cardNumber
     */
    @ApiModelProperty(value="银行卡号",example="6228480028285916456",required=true)
    @NotBlank(message = "银行卡设置默认收还款标志请求银行卡号不能为空")
    @Pattern(regexp = RegexConstant.BANKCARD_NUMBER,message = "银行卡号格式不正确")
    private String cardNumber;
    /**
     * 收还款标志类型
     * 表字段:flagType
     */
    @ApiModelProperty(value="收还款标志类型",example="0",required=true)
    @NotBlank(message = "银行卡设置默认收还款标志请求收还款标志类型不能为空")
    @Pattern(regexp = RegexConstant.BANKCARD_BINDTYPE,message = "收还款标志类型只能是0,1,2")
    private String flagType;

    @Override
    public String toString() {
        return "BankCardSetFlagReq{" +
                ", cardNumber='" + cardNumber + '\'' +
                ", flagType='" + flagType + '\'' +
                '}';
    }

    public String getCardNumber() {
        return cardNumber;
    }

    public void setCardNumber(String cardNumber) {
        this.cardNumber = cardNumber;
    }

    public String getFlagType() {
        return flagType;
    }

    public void setFlagType(String flagType) {
        this.flagType = flagType;
    }
}
